#import <Foundation/Foundation.h>

@interface BlankScreenCheck : NSObject

/**
 * 检查WebView白屏
 * @{
 * @"result":BOOL
 * @"most_rgb_pixel_num":@"",
 * @"total_select_pexel":@"",
 * @"blankH":@"",
 * @"consuming_time":@"",
 * @"blankW":@"",
 * @"pure_colour_percent":@"",
 * @"most_rgb_pixel":@"",
 * @"ret":@"0",
 * @"delay_time":@""
 * }
 * 可以在子线程工作
 */
+ (void)checkBlankWebView:(CGRect)webViewFrame
                    image:(UIImage *)image
              resultBlock:(void(^)(NSDictionary *))resultBlock;

/**
 * 截屏方法，必须在主线程工作
 */
+ (UIImage *)screenshot:(UIView *)view;

/**
 * 截屏方法，必须在主线程工作
 */
+ (UIImage *)screenshot:(UIView *)view rectInset:(CGRect)rectInset;

/**
 * 必须在主线程工作
 */
+ (UIImage *)getSubImage:(CGRect)rect image:(UIImage *)image;

@end
